using DG.Tweening;
using UnityEngine;

public class UIHealthBar : EnemyHealthBar
{
    private CanvasGroup canvasGroup;
    protected override void Awake()
    {
        base.Awake();
        transform.SetParent(UIManager.Instance.gameUICanvas.transform, false);
        canvasGroup = GetComponent<CanvasGroup>();
    }

    protected override void OnEnable()
    {
        base.OnEnable();
        canvasGroup.alpha = 0;
        canvasGroup.DOFade(1, 0.5f).SetEase(Ease.OutQuad);
    }
}